<?php /* Smarty version 2.6.26, created on 2010-04-29 08:53:53
         compiled from admin/updateRuler.tpl */ ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link type="text/css" rel="stylesheet" href="webapps/styles/table_dis.css" />
<script type="text/javascript" src="webapps/scripts/jquery.js"></script>
<script type="text/javascript">
$(document).ready(function(){
	//添加颜色变化
	$("#tab tr").hover(function(){$(this).css("background","#DEEBFC");},function(){$(this).css("background","#FFF");});
	//表单提交验证
	$("#updateRuler").submit(function(){
		var password = $("#password").val();
		var new_password = $("#new_password").val();
		var r_new_password = $("#r_new_password").val();
		
		if(password == ""){
			alert("密码不能为空！");
			return false;
		}
		
		if(new_password == ""){
			alert("新密码不能为空！");
			return false;
		}
		
		if(r_new_password == ""){
			alert("确认密码不能为空！");
			return false;
		}
		
		if(new_password != r_new_password){
			alert("新密码和确认密码不匹配！");
			return false;
		}
		
		return true;
	});
});
</script>
<title><?php echo $this->_tpl_vars['title']; ?>
</title>
</head>

<body>
<form id="updateRuler" action="index.php?controller=admin&action=updateRulerAction" method="post">
<table width="100%" cellpadding="1" cellspacing="1" border="0" id="tab">
  <tr>
    <th colspan="2" style="background-color:#4F9AD0;">更新管理员</th>
  </tr>
  <tr>
    <td width="9%">用户名</td>
    <td width="91%"><?php echo $this->_tpl_vars['res_ruler']['username']; ?>
<input type="hidden" id="id" name="id" value="<?php echo $this->_tpl_vars['res_ruler']['id']; ?>
" /></td>
  </tr>
  <tr>
    <td width="9%">原来密码</td>
    <td width="91%"><input type="password" id="password" name="password" style="width:180px;" /> <span style="color:#933;">*用户密码必须</span></td>
  </tr>
  <tr>
    <td width="9%">新的密码</td>
    <td width="91%"><input type="password" id="new_password" name="new_password" style="width:180px;" /> 
    <span style="color:#933;">*新的密码必须</span></td>
  </tr>
  <tr>
    <td width="9%">确认密码</td>
    <td width="91%"><input type="password" id="r_new_password" name="r_new_password" style="width:180px;" /> 
    <span style="color:#933;">*确认密码码必须</span></td>
  </tr>
  <tr>
    <td colspan="2" style="padding-left:96px;"><input type="submit" name="submit" value="提交" /> <input type="reset" name="reset" value="重置" /></td>
  </tr>
</table>
</form>
</body>
</html>